package com.api.shopapi.service.impl;

import com.api.shopapi.entity.DishesPlanNightItem;
import com.api.shopapi.mapper.DishesPlanNightItemMapper;
import com.api.shopapi.service.DishesPlanNightItemService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service("DishesPlanNightItemServiceImplOne")
public class DishesPlanNightItemServiceImplOne implements DishesPlanNightItemService {

    @Autowired
    private DishesPlanNightItemMapper dishesPlanNightItemMapper;

    @Override
    public
    int insert(DishesPlanNightItem dishesPlanNightItem){
        return dishesPlanNightItemMapper.insert(dishesPlanNightItem);
    }

    @Override
    public
    int delete(String dishesPlanNightItemCode){
        return dishesPlanNightItemMapper.delete(dishesPlanNightItemCode);
    }

    @Override
    public
    int update(DishesPlanNightItem dishesPlanNightItem){
        return dishesPlanNightItemMapper.update(dishesPlanNightItem);
    }

    @Override
    public
    DishesPlanNightItem getByDishesPlanNightItemCode(String dishesPlanNightItemCode){
        return dishesPlanNightItemMapper.getByDishesPlanNightItemCode(dishesPlanNightItemCode);
    }

    @Override
    public
    List<DishesPlanNightItem> ListByDishesPlanNightCode(String dishesPlanNightCode){
        return dishesPlanNightItemMapper.ListByDishesPlanNightCode(dishesPlanNightCode);
    }

}
